{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 二、收集数据和预处理"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 186,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>订单号</th>\n",
       "      <th>产品码</th>\n",
       "      <th>消费日期</th>\n",
       "      <th>产品说明</th>\n",
       "      <th>数量</th>\n",
       "      <th>单价</th>\n",
       "      <th>用户码</th>\n",
       "      <th>城市</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>536374</td>\n",
       "      <td>21258</td>\n",
       "      <td>6/1/2020 9:09</td>\n",
       "      <td>五彩玫瑰五支装</td>\n",
       "      <td>32</td>\n",
       "      <td>10.95</td>\n",
       "      <td>15100</td>\n",
       "      <td>北京</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>536376</td>\n",
       "      <td>22114</td>\n",
       "      <td>6/1/2020 9:32</td>\n",
       "      <td>茉莉花白色25枝</td>\n",
       "      <td>48</td>\n",
       "      <td>3.45</td>\n",
       "      <td>15291</td>\n",
       "      <td>上海</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>536376</td>\n",
       "      <td>21733</td>\n",
       "      <td>6/1/2020 9:32</td>\n",
       "      <td>教师节向日葵3枝尤加利5枝</td>\n",
       "      <td>64</td>\n",
       "      <td>2.55</td>\n",
       "      <td>15291</td>\n",
       "      <td>上海</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>536378</td>\n",
       "      <td>22386</td>\n",
       "      <td>6/1/2020 9:37</td>\n",
       "      <td>百合粉色10花苞</td>\n",
       "      <td>10</td>\n",
       "      <td>1.95</td>\n",
       "      <td>14688</td>\n",
       "      <td>北京</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>536378</td>\n",
       "      <td>85099C</td>\n",
       "      <td>6/1/2020 9:37</td>\n",
       "      <td>橙黄香槟色康乃馨</td>\n",
       "      <td>10</td>\n",
       "      <td>1.95</td>\n",
       "      <td>14688</td>\n",
       "      <td>北京</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      订单号     产品码           消费日期           产品说明  数量     单价    用户码  城市\n",
       "0  536374   21258  6/1/2020 9:09        五彩玫瑰五支装  32  10.95  15100  北京\n",
       "1  536376   22114  6/1/2020 9:32       茉莉花白色25枝  48   3.45  15291  上海\n",
       "2  536376   21733  6/1/2020 9:32  教师节向日葵3枝尤加利5枝  64   2.55  15291  上海\n",
       "3  536378   22386  6/1/2020 9:37       百合粉色10花苞  10   1.95  14688  北京\n",
       "4  536378  85099C  6/1/2020 9:37       橙黄香槟色康乃馨  10   1.95  14688  北京"
      ]
     },
     "execution_count": 186,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd \n",
    "\n",
    "df_sales = pd.read_csv('data.csv')\n",
    "df_sales.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 2.2 数据可视化"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 187,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "消费日期\n",
      "2020-06-30    398\n",
      "2020-07-31    252\n",
      "2020-08-31    271\n",
      "2020-09-30    337\n",
      "2020-10-31    272\n",
      "Freq: M, Name: 订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yLSJSuD529/fi1METgRc9zAz2HtCHUGjfB+Dufwc6mVn7+H+fcfdV7v4ZsAAor+NvjHH32fFvjI+/V0RE6qDiWkSkcK3K+bkq530V4c5kbV04qqflzf2/66j7TuaGriciIqi4FhHJsleAk2F9F4/P3P3zetZfRugmIiIim0gtECIi2XU1cLeZTQC+AE6rb2V3XxgfiHwfeBZ4pvFDFBHJFgvd80REREREZHOpW4iIiIiISJ6ouBYRERERyRMV1yIiIiIieaLiWkREREQkT1Rci4iIiIjkiYprEREREZE8UXEtIiIiIpIn/wepIIIU2IysrwAAAABJRU5ErkJggg==",
      "text/plain": [
       "<Figure size 864x432 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "import matplotlib.pyplot as plt\n",
    "df_sales['消费日期'] = pd.to_datetime(df_sales['消费日期'])\n",
    "df_orders_monthly = df_sales.set_index('消费日期')['订单号'].resample('M').nunique() # 计算每个月的订单数量\n",
    "print(df_orders_monthly.head())\n",
    "\n",
    "ax = pd.DataFrame(df_orders_monthly.values).plot(grid=True,figsize=(12,6),legend=False)\n",
    "ax.set_xlabel('month')\n",
    "ax.set_ylabel('order num')\n",
    "ax.set_title('order num every month')\n",
    "\n",
    "plt.xticks(range(len(df_orders_monthly.index)),\n",
    "            [x.strftime('%m.%Y') for x in df_orders_monthly.index],\n",
    "            rotation=45)\n",
    "plt.show()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 2.3 数据清洗"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 188,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>数量</th>\n",
       "      <th>单价</th>\n",
       "      <th>用户码</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>count</th>\n",
       "      <td>85920.000000</td>\n",
       "      <td>85920.000000</td>\n",
       "      <td>85920.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>mean</th>\n",
       "      <td>10.115747</td>\n",
       "      <td>3.599711</td>\n",
       "      <td>15338.080389</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>std</th>\n",
       "      <td>49.114285</td>\n",
       "      <td>134.410498</td>\n",
       "      <td>391.309086</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>min</th>\n",
       "      <td>-9360.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>14681.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25%</th>\n",
       "      <td>2.000000</td>\n",
       "      <td>1.250000</td>\n",
       "      <td>15022.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50%</th>\n",
       "      <td>4.000000</td>\n",
       "      <td>1.950000</td>\n",
       "      <td>15334.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>75%</th>\n",
       "      <td>12.000000</td>\n",
       "      <td>3.750000</td>\n",
       "      <td>15673.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>max</th>\n",
       "      <td>3114.000000</td>\n",
       "      <td>38970.000000</td>\n",
       "      <td>16019.000000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                 数量            单价           用户码\n",
       "count  85920.000000  85920.000000  85920.000000\n",
       "mean      10.115747      3.599711  15338.080389\n",
       "std       49.114285    134.410498    391.309086\n",
       "min    -9360.000000      0.000000  14681.000000\n",
       "25%        2.000000      1.250000  15022.000000\n",
       "50%        4.000000      1.950000  15334.000000\n",
       "75%       12.000000      3.750000  15673.000000\n",
       "max     3114.000000  38970.000000  16019.000000"
      ]
     },
     "execution_count": 188,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_sales = df_sales.drop_duplicates() # 删除重复行\n",
    "\n",
    "df_sales.describe() # 通过统计信息查看是否有脏数据"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 189,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>数量</th>\n",
       "      <th>单价</th>\n",
       "      <th>用户码</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>count</th>\n",
       "      <td>84112.000000</td>\n",
       "      <td>84112.000000</td>\n",
       "      <td>84112.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>mean</th>\n",
       "      <td>10.760236</td>\n",
       "      <td>3.005032</td>\n",
       "      <td>15337.732963</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>std</th>\n",
       "      <td>34.018906</td>\n",
       "      <td>15.365085</td>\n",
       "      <td>392.074855</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>min</th>\n",
       "      <td>1.000000</td>\n",
       "      <td>0.000000</td>\n",
       "      <td>14681.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25%</th>\n",
       "      <td>2.000000</td>\n",
       "      <td>1.250000</td>\n",
       "      <td>15021.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50%</th>\n",
       "      <td>5.000000</td>\n",
       "      <td>1.950000</td>\n",
       "      <td>15333.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>75%</th>\n",
       "      <td>12.000000</td>\n",
       "      <td>3.750000</td>\n",
       "      <td>15674.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>max</th>\n",
       "      <td>3114.000000</td>\n",
       "      <td>3155.950000</td>\n",
       "      <td>16019.000000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                 数量            单价           用户码\n",
       "count  84112.000000  84112.000000  84112.000000\n",
       "mean      10.760236      3.005032  15337.732963\n",
       "std       34.018906     15.365085    392.074855\n",
       "min        1.000000      0.000000  14681.000000\n",
       "25%        2.000000      1.250000  15021.000000\n",
       "50%        5.000000      1.950000  15333.000000\n",
       "75%       12.000000      3.750000  15674.000000\n",
       "max     3114.000000   3155.950000  16019.000000"
      ]
     },
     "execution_count": 189,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_sales = df_sales.loc[df_sales['数量'] > 0]\n",
    "df_sales.describe()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## 2.4 特征工程"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 190,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>订单号</th>\n",
       "      <th>产品码</th>\n",
       "      <th>消费日期</th>\n",
       "      <th>产品说明</th>\n",
       "      <th>数量</th>\n",
       "      <th>单价</th>\n",
       "      <th>用户码</th>\n",
       "      <th>城市</th>\n",
       "      <th>总价</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>536374</td>\n",
       "      <td>21258</td>\n",
       "      <td>2020-06-01 09:09:00</td>\n",
       "      <td>五彩玫瑰五支装</td>\n",
       "      <td>32</td>\n",
       "      <td>10.95</td>\n",
       "      <td>15100</td>\n",
       "      <td>北京</td>\n",
       "      <td>350.4</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>536376</td>\n",
       "      <td>22114</td>\n",
       "      <td>2020-06-01 09:32:00</td>\n",
       "      <td>茉莉花白色25枝</td>\n",
       "      <td>48</td>\n",
       "      <td>3.45</td>\n",
       "      <td>15291</td>\n",
       "      <td>上海</td>\n",
       "      <td>165.6</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>536376</td>\n",
       "      <td>21733</td>\n",
       "      <td>2020-06-01 09:32:00</td>\n",
       "      <td>教师节向日葵3枝尤加利5枝</td>\n",
       "      <td>64</td>\n",
       "      <td>2.55</td>\n",
       "      <td>15291</td>\n",
       "      <td>上海</td>\n",
       "      <td>163.2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>536378</td>\n",
       "      <td>22386</td>\n",
       "      <td>2020-06-01 09:37:00</td>\n",
       "      <td>百合粉色10花苞</td>\n",
       "      <td>10</td>\n",
       "      <td>1.95</td>\n",
       "      <td>14688</td>\n",
       "      <td>北京</td>\n",
       "      <td>19.5</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>536378</td>\n",
       "      <td>85099C</td>\n",
       "      <td>2020-06-01 09:37:00</td>\n",
       "      <td>橙黄香槟色康乃馨</td>\n",
       "      <td>10</td>\n",
       "      <td>1.95</td>\n",
       "      <td>14688</td>\n",
       "      <td>北京</td>\n",
       "      <td>19.5</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      订单号     产品码                消费日期           产品说明  数量     单价    用户码  城市  \\\n",
       "0  536374   21258 2020-06-01 09:09:00        五彩玫瑰五支装  32  10.95  15100  北京   \n",
       "1  536376   22114 2020-06-01 09:32:00       茉莉花白色25枝  48   3.45  15291  上海   \n",
       "2  536376   21733 2020-06-01 09:32:00  教师节向日葵3枝尤加利5枝  64   2.55  15291  上海   \n",
       "3  536378   22386 2020-06-01 09:37:00       百合粉色10花苞  10   1.95  14688  北京   \n",
       "4  536378  85099C 2020-06-01 09:37:00       橙黄香槟色康乃馨  10   1.95  14688  北京   \n",
       "\n",
       "      总价  \n",
       "0  350.4  \n",
       "1  165.6  \n",
       "2  163.2  \n",
       "3   19.5  \n",
       "4   19.5  "
      ]
     },
     "execution_count": 190,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_sales['总价'] = df_sales['数量'] * df_sales['单价']\n",
    "df_sales.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 191,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码\n",
       "0  14681\n",
       "1  14682\n",
       "2  14684\n",
       "3  14687\n",
       "4  14688"
      ]
     },
     "execution_count": 191,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user = pd.DataFrame(df_sales['用户码'].unique())\n",
    "df_user.columns = ['用户码']\n",
    "df_user = df_user.sort_values(by='用户码',ascending=True).reset_index(drop=True)\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "求R值"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 192,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值\n",
       "0  14681   70\n",
       "1  14682  187\n",
       "2  14684   25\n",
       "3  14687  106\n",
       "4  14688    7"
      ]
     },
     "execution_count": 192,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_sales['消费日期'] = pd.to_datetime(df_sales['消费日期'])\n",
    "df_recent_buy = df_sales.groupby('用户码').消费日期.max().reset_index()\n",
    "df_recent_buy.columns = ['用户码', '最近日期']\n",
    "# 用数据源中的最大消费日期 - 每个用户的最近消费日期\n",
    "df_recent_buy['R值'] = (df_recent_buy['最近日期'].max() - df_recent_buy['最近日期']).dt.days\n",
    "df_user = pd.merge(df_user, df_recent_buy[['用户码','R值']], on='用户码')\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "求F值"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 193,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "      <th>F值</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "      <td>7</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "      <td>390</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "      <td>15</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "      <td>324</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值   F值\n",
       "0  14681   70    7\n",
       "1  14682  187    2\n",
       "2  14684   25  390\n",
       "3  14687  106   15\n",
       "4  14688    7  324"
      ]
     },
     "execution_count": 193,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_frequency = df_sales.groupby('用户码').消费日期.count().reset_index()\n",
    "df_frequency.columns = ['用户码', 'F值']\n",
    "df_user = pd.merge(df_user, df_frequency, on='用户码')\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "求M值"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 194,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "      <th>F值</th>\n",
       "      <th>M值</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "      <td>7</td>\n",
       "      <td>498.95</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "      <td>2</td>\n",
       "      <td>52.00</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "      <td>390</td>\n",
       "      <td>1201.51</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "      <td>15</td>\n",
       "      <td>628.38</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "      <td>324</td>\n",
       "      <td>5579.10</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值   F值       M值\n",
       "0  14681   70    7   498.95\n",
       "1  14682  187    2    52.00\n",
       "2  14684   25  390  1201.51\n",
       "3  14687  106   15   628.38\n",
       "4  14688    7  324  5579.10"
      ]
     },
     "execution_count": 194,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_revenue = df_sales.groupby('用户码').总价.sum().reset_index()\n",
    "df_revenue.columns = ['用户码', 'M值']\n",
    "df_user = pd.merge(df_user, df_revenue, on='用户码')\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 195,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x115edb00>"
      ]
     },
     "execution_count": 195,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUg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+cs/GzpPl+lERmeFfBG4fTYXoznT64GvdPdHLXKudzGaWvgeo3/tvGyuTIx2l/+u2663AusGzPi2LsMtjH4JV42t/2ddxjuAMxYh3y8wmja4Bdjc3c6cpu04T8Zp2o5PAb7QZbkN+Itu/ERG5bQVeC9waDd+WPd4a/f8iQNm/GS3HW8D3s4Pz3Qa5Hdm0puX2pAkNS3HKSZJ0gQsCElSkwUhSWqyICRJTRaEJKnJgpAkNVkQkqSm/wdiANIhouPi0wAAAABJRU5ErkJggg==",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "df_user['R值'].plot(kind='hist', bins=20, title='R') # bins 柱子数量"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 196,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x11539470>"
      ]
     },
     "execution_count": 196,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYgAAAEICAYAAABF82P+AAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAEcJJREFUeJzt3XusZWV9xvHvI6BcpAIy0JGLBxpCpY0CHRGDtShiuVTQRi3EKDHoNBVSiU3qYI3aP0xoU63aC4pKBasgF7lUsAp4SxsFBkQuAjLqVMZBZtQKXqgI/vrHXkeO4ztz9jBnn7XOnO8n2dlrvXudvZ8zbOaZ9a61105VIUnShp7QdwBJ0jBZEJKkJgtCktRkQUiSmiwISVKTBSFJarIgJElNFoQ0h5KsTvJQkp/MuD2t71zS47Ft3wGkrdBLquravkNIW8o9CElSkwUhSWqyIKS5d3mSH3W3y/sOIz1eHoOQ5t5LPQ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PQu6KQlCfBh4M6qevfAsy5Jsku3vAPwIuBO4PPAyzeSdfp3eDnwueomdyetqs6sqr2raorRe/JzVfWqIWZNslOSnaeXGc2X384A3wNV9T3g3iQHdkNHMfrqgMFlneFkHptems7UX9b5PgDT943R0f9vMJqP/pu+83SZLgDuA37B6F8GpzKaU74OuKe7363bNoy+VOmbwG3AsnnM+TxGu7G3Ard0t+MGmvWZwFe7rLcDb+vG9wduAFYx2o1/Uje+fbe+qnt8/57eC0fy2FlMg8vaZfpad7tj+v+hIb4Hutc/GFjZvQ8uB3YdcNYdgR8AT5kx1mtWL7UhSWpabFNMkqQxWRCSpCYLQpLUZEFIkposCElSkwUhSWqyICRJTf8PquO6I1Q7bnMAAAAASUVORK5CYII=",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "df_user.query('F值 < 800')['F值'].plot(kind='hist', bins=50, title='F')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 197,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.axes._subplots.AxesSubplot at 0x114fe400>"
      ]
     },
     "execution_count": 197,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYkAAAEICAYAAACqMQjAAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAFvxJREFUeJzt3X2wZHV95/H3xwEVH4EwupMBvOhOjJiNA7kiW8asARMRV0eTaKBSyhqSMRuojRuz5aipSKqWKkxUopVdzLiyAlEBn1bWh41IfChrAzjgyINAGGGUYWaZUVF8CgT87h/9u7EZ7rm378O53cy8X1Vdfc6vz8O3T/ftzz3nd/p0qgpJkmbziHEXI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DELuAf2bwH9npy7mNgGnghjbPX9OuhrDIurYxOCY98157d5v2N9tr/FXgWuAl862/6zkuobZle/3ae/fq9nw/BDxqsXW19vcBf7DXtCu2zej+nBjr+8zLckiSOu2PfRKSpBEZEpKkToaEJKmTISFJ6mRISJI6GRKSpE6GhCSp0/8HGIUToQKsd7oAAAAASUVORK5CYII=",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "df_user.query('M值 < 20000')['M值'].plot(kind='hist', bins=50, title='M')"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# 三、选择算法并建立模型"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "手肘法确定K值"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 198,
   "metadata": {},
   "outputs": [],
   "source": [
    "from sklearn.cluster import KMeans\n",
    "\n",
    "def show_elbow(df):     # 定义手肘函数\n",
    "    distance_list = [] # 距质心的距离\n",
    "    K = range(1, 9) # K值范围\n",
    "    for k in K:\n",
    "        kmeans = KMeans(n_clusters=k, max_iter=100) # 创建 KMeans 模型，最大迭代100次\n",
    "        kmeans = kmeans.fit(df) # 拟合模型\n",
    "        distance_list.append(kmeans.inertia_) # 每个K值的损失\n",
    "    plt.plot(K, distance_list, 'bx-')\n",
    "    plt.xlabel('k')\n",
    "    plt.ylabel('距离均方误差')\n",
    "    plt.title('k_elbow')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 199,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYUAAAEWCAYAAACJ0YulAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAHtZJREFUeJz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XQmIrZExMGkp+vNlFSRXXSS3gOsj4gledfSDUdHxKHAycAni12hlWgQcChweUQcArwKnJdvSV0rdnPNBW7Iu5aOSHobMA+YDOwJDJN0Zlbfz6FQgYp98zcB/xURP8u7nnIVuwvuBE7KuZSOHA3MLfbTXwecIOkn+ZbUuYhYV/y6Hvj/wMx8K+rQWmBtyVXijaSQqHQnAw9GxJ/zLqQTc4CnImJDRLwF/Aw4Kqtv5lCoMMWB2x8AKyPiW3nX0xVJdZJ2K+7vTPoH/Id8q2pfRJwfEeMiYhKpy+COiMjsL64dJWlYcbIBxa6YAlCRM+gi4k/AGklTi6dmAxU5OaKNM6jgrqOiPwJHSNql+PthNmmsMRM1EQqSrgXuA6ZKWivp43nX1Imjgb8l/RXbPF3ulLyL6sQeQIOkZaTnct8WERU/1bNKjAHukbQU+D3wq4j4Tc41deZTwH8V/y0cDHw953o6JWkX4ETSX94Vq3j1dSPwILCc9Hs7s+UuamJKqpmZlacmrhTMzKw8DgUzM2vhUDAzsxYOBTMza+FQMDOzFg4Fsx0kaVI1rMBrVg6HgpmZtXAomPUiSXsVF4SbkXctZj3hUDDrJcUlHm4C/j4iFuddj1lPDMq7ALN+og74BfA3EbEi72LMespXCma942VgDWntKrOq5SsFs97RBLwPuEXSpoi4Ju+CzHrCoWDWSyLi1eKDfG6T9GpE/CLvmsy6y6ukmplZC48pmJlZC4eCmZm1cCiYmVkLh4KZmbVwKJiZWQuHgpmZtXAomJlZi/8Gm7RUliDUBAIAAAAASUVORK5CYII=",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "show_elbow(df_user[['R值']])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 200,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYUAAAEWCAYAAACJ0YulAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgA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2B4wl/eWetVOtrCjAX+Dvh93Zi210UxJRUERFJT0G0FEREJD0KBRERqaZQEBGRagoFERGpplAQEZFqCgWRVmBmfXNhF16RpigURESkmkJBpJWZ2TdTm8LotUhfAAAAl0lEQVT1j12LSHMpFERaUWqbh0eB8919dux6RJqrXewCRPJIEfBn4HR3fyt2MSItoZaCSOtZDSwh7F8lkpPUUhBpPeuAU4Gnzewzd38odkEizaVQEGlF7v556jCfZ83sc3f/c+yaRJpDu6SKiEg1jSmIiEg1hYKIiFRTKIiISDWFgoiIVFMoiIhINYWCiIhUUyiIiEi1/wMIgVex4kL11gAAAABJRU5ErkJggg==",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "show_elbow(df_user[['F值']])"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 201,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYwAAAEWCAYAAAB1xKBvAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAIABJREFUeJzt3XuUXWV9//H3h1xJABPMNAVCSKDIRYQAkyCiQARDLkcuVTB4KQhtFq14q63iBahoq6Wt2l+XohSoUC0IaEsIl4AwBBAiMwkECIhAoBCCZiBAIFxiku/vj2dPczKZy5nJ7Nnn8nmttdc5+3bOd1hkPrOf59nPVkRgZmbWm+2KLsDMzGqDA8PMzCriwDAzs4o4MMzMrCIODDMzq4gDw8zMKuLAMDOzijgwzDKSnpZ07AB91t9J+kn2fpKkkDR0ID7brCgODDMzq4gDw8zMKuLAMOuCpH0lPSVpbg/H7Crp55Las2M/08vHniFplaTnJX2h7HNGSPpetm9V9n5Etm+RpA9l79+bNW3NztaPlfTA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cAwM7OKODDMBomkPbPJ96YWXYtZfzgwzAZBNi3Gz4FPRkRr0fWY9cfQogswawBNwHXAhyJiedHFmPWXrzDM8vcK8CxpLjCzmuUrDLP8rQdOBBZKei0i/qvogsz6w4FhNggiYl32kKZbJa2LiOuKrsmsrzxbrZmZVcR9GGZmVhEHhpmZVcSBYWZmFXFgmJlZRRwYZmZWEQeGmZlVxIFhZmYV+f+d/Bb956cOoAAAAABJRU5ErkJggg==",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "show_elbow(df_user[['M值']])"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "创建和训练模型"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 202,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "KMeans(algorithm='auto', copy_x=True, init='k-means++', max_iter=300,\n",
       "    n_clusters=4, n_init=10, n_jobs=1, precompute_distances='auto',\n",
       "    random_state=None, tol=0.0001, verbose=0)"
      ]
     },
     "execution_count": 202,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "from sklearn.cluster import KMeans\n",
    "\n",
    "kmeans_R = KMeans(n_clusters=3)\n",
    "kmeans_F = KMeans(n_clusters=4)\n",
    "kmeans_M = KMeans(n_clusters=4)\n",
    "\n",
    "kmeans_R.fit(df_user[['R值']])\n",
    "kmeans_F.fit(df_user[['F值']])\n",
    "kmeans_M.fit(df_user[['M值']])"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "使用模型进行聚类"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 203,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "      <th>F值</th>\n",
       "      <th>M值</th>\n",
       "      <th>R值层级</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "      <td>7</td>\n",
       "      <td>498.95</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "      <td>2</td>\n",
       "      <td>52.00</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "      <td>390</td>\n",
       "      <td>1201.51</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "      <td>15</td>\n",
       "      <td>628.38</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "      <td>324</td>\n",
       "      <td>5579.10</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值   F值       M值  R值层级\n",
       "0  14681   70    7   498.95     0\n",
       "1  14682  187    2    52.00     2\n",
       "2  14684   25  390  1201.51     0\n",
       "3  14687  106   15   628.38     2\n",
       "4  14688    7  324  5579.10     0"
      ]
     },
     "execution_count": 203,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user['R值层级'] = kmeans_R.predict(df_user[['R值']]) # 不需要进行模型的评估和优化\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 204,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>count</th>\n",
       "      <th>mean</th>\n",
       "      <th>std</th>\n",
       "      <th>min</th>\n",
       "      <th>25%</th>\n",
       "      <th>50%</th>\n",
       "      <th>75%</th>\n",
       "      <th>max</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>R值层级</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>664.0</td>\n",
       "      <td>32.088855</td>\n",
       "      <td>25.141763</td>\n",
       "      <td>0.0</td>\n",
       "      <td>10.00</td>\n",
       "      <td>25.0</td>\n",
       "      <td>50.00</td>\n",
       "      <td>94.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>138.0</td>\n",
       "      <td>298.094203</td>\n",
       "      <td>45.436550</td>\n",
       "      <td>231.0</td>\n",
       "      <td>255.25</td>\n",
       "      <td>292.5</td>\n",
       "      <td>334.50</td>\n",
       "      <td>372.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>178.0</td>\n",
       "      <td>157.162921</td>\n",
       "      <td>37.340870</td>\n",
       "      <td>95.0</td>\n",
       "      <td>126.00</td>\n",
       "      <td>156.5</td>\n",
       "      <td>188.75</td>\n",
       "      <td>225.0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      count        mean        std    min     25%    50%     75%    max\n",
       "R值层级                                                                   \n",
       "0     664.0   32.088855  25.141763    0.0   10.00   25.0   50.00   94.0\n",
       "1     138.0  298.094203  45.436550  231.0  255.25  292.5  334.50  372.0\n",
       "2     178.0  157.162921  37.340870   95.0  126.00  156.5  188.75  225.0"
      ]
     },
     "execution_count": 204,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user.groupby('R值层级')['R值'].describe()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "聚类后概念化"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 205,
   "metadata": {},
   "outputs": [],
   "source": [
    "def order_cluster(cluster_name, target_name, df, ascending=False):\n",
    "    df_new = df.groupby(cluster_name)[target_name].mean().reset_index() #按聚类结果分组，创建df_new对象\n",
    "    df_new = df_new.sort_values(by=target_name,ascending=ascending).reset_index(drop=True)\n",
    "    df_new['index'] = df_new.index\n",
    "    df_new = pd.merge(df, df_new[[cluster_name, 'index']],on=cluster_name)\n",
    "    df_new = df_new.drop([cluster_name], axis=1)\n",
    "    df_new = df_new.rename(columns={'index':cluster_name})\n",
    "    return df_new"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 206,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "      <th>F值</th>\n",
       "      <th>M值</th>\n",
       "      <th>R值层级</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "      <td>7</td>\n",
       "      <td>498.95</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "      <td>2</td>\n",
       "      <td>52.00</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "      <td>390</td>\n",
       "      <td>1201.51</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "      <td>15</td>\n",
       "      <td>628.38</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "      <td>324</td>\n",
       "      <td>5579.10</td>\n",
       "      <td>2</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值   F值       M值  R值层级\n",
       "0  14681   70    7   498.95     2\n",
       "1  14682  187    2    52.00     1\n",
       "2  14684   25  390  1201.51     2\n",
       "3  14687  106   15   628.38     1\n",
       "4  14688    7  324  5579.10     2"
      ]
     },
     "execution_count": 206,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user = order_cluster('R值层级', 'R值', df_user, False)\n",
    "df_user = df_user.sort_values(by='用户码',ascending=True).reset_index(drop=True)\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 207,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>count</th>\n",
       "      <th>mean</th>\n",
       "      <th>std</th>\n",
       "      <th>min</th>\n",
       "      <th>25%</th>\n",
       "      <th>50%</th>\n",
       "      <th>75%</th>\n",
       "      <th>max</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>R值层级</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>138.0</td>\n",
       "      <td>298.094203</td>\n",
       "      <td>45.436550</td>\n",
       "      <td>231.0</td>\n",
       "      <td>255.25</td>\n",
       "      <td>292.5</td>\n",
       "      <td>334.50</td>\n",
       "      <td>372.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>178.0</td>\n",
       "      <td>157.162921</td>\n",
       "      <td>37.340870</td>\n",
       "      <td>95.0</td>\n",
       "      <td>126.00</td>\n",
       "      <td>156.5</td>\n",
       "      <td>188.75</td>\n",
       "      <td>225.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>664.0</td>\n",
       "      <td>32.088855</td>\n",
       "      <td>25.141763</td>\n",
       "      <td>0.0</td>\n",
       "      <td>10.00</td>\n",
       "      <td>25.0</td>\n",
       "      <td>50.00</td>\n",
       "      <td>94.0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      count        mean        std    min     25%    50%     75%    max\n",
       "R值层级                                                                   \n",
       "0     138.0  298.094203  45.436550  231.0  255.25  292.5  334.50  372.0\n",
       "1     178.0  157.162921  37.340870   95.0  126.00  156.5  188.75  225.0\n",
       "2     664.0   32.088855  25.141763    0.0   10.00   25.0   50.00   94.0"
      ]
     },
     "execution_count": 207,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user.groupby('R值层级')['R值'].describe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 208,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>count</th>\n",
       "      <th>mean</th>\n",
       "      <th>std</th>\n",
       "      <th>min</th>\n",
       "      <th>25%</th>\n",
       "      <th>50%</th>\n",
       "      <th>75%</th>\n",
       "      <th>max</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>F值层级</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>720.0</td>\n",
       "      <td>32.277778</td>\n",
       "      <td>24.128263</td>\n",
       "      <td>1.0</td>\n",
       "      <td>12.00</td>\n",
       "      <td>27.0</td>\n",
       "      <td>48.25</td>\n",
       "      <td>92.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>203.0</td>\n",
       "      <td>152.960591</td>\n",
       "      <td>50.338738</td>\n",
       "      <td>93.0</td>\n",
       "      <td>113.50</td>\n",
       "      <td>138.0</td>\n",
       "      <td>191.50</td>\n",
       "      <td>279.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>50.0</td>\n",
       "      <td>417.080000</td>\n",
       "      <td>109.618232</td>\n",
       "      <td>289.0</td>\n",
       "      <td>329.75</td>\n",
       "      <td>390.0</td>\n",
       "      <td>492.50</td>\n",
       "      <td>710.0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>7.0</td>\n",
       "      <td>1281.000000</td>\n",
       "      <td>515.121345</td>\n",
       "      <td>887.0</td>\n",
       "      <td>996.50</td>\n",
       "      <td>1112.0</td>\n",
       "      <td>1304.50</td>\n",
       "      <td>2366.0</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      count         mean         std    min     25%     50%      75%     max\n",
       "F值层级                                                                        \n",
       "0     720.0    32.277778   24.128263    1.0   12.00    27.0    48.25    92.0\n",
       "1     203.0   152.960591   50.338738   93.0  113.50   138.0   191.50   279.0\n",
       "2      50.0   417.080000  109.618232  289.0  329.75   390.0   492.50   710.0\n",
       "3       7.0  1281.000000  515.121345  887.0  996.50  1112.0  1304.50  2366.0"
      ]
     },
     "execution_count": 208,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user['F值层级'] = kmeans_F.predict(df_user[['F值']])\n",
    "df_user = order_cluster('F值层级', 'F值', df_user, True)\n",
    "df_user.groupby('F值层级')['F值'].describe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 209,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>count</th>\n",
       "      <th>mean</th>\n",
       "      <th>std</th>\n",
       "      <th>min</th>\n",
       "      <th>25%</th>\n",
       "      <th>50%</th>\n",
       "      <th>75%</th>\n",
       "      <th>max</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>M值层级</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>805.0</td>\n",
       "      <td>645.886970</td>\n",
       "      <td>502.084453</td>\n",
       "      <td>6.20</td>\n",
       "      <td>254.11</td>\n",
       "      <td>475.28</td>\n",
       "      <td>954.090</td>\n",
       "      <td>2102.54</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>141.0</td>\n",
       "      <td>3575.166312</td>\n",
       "      <td>1290.594158</td>\n",
       "      <td>2114.33</td>\n",
       "      <td>2533.42</td>\n",
       "      <td>3213.59</td>\n",
       "      <td>4405.880</td>\n",
       "      <td>7354.62</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>27.0</td>\n",
       "      <td>11434.159259</td>\n",
       "      <td>3399.310286</td>\n",
       "      <td>7616.53</td>\n",
       "      <td>8242.11</td>\n",
       "      <td>10484.99</td>\n",
       "      <td>12870.455</td>\n",
       "      <td>19766.59</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>7.0</td>\n",
       "      <td>46663.441429</td>\n",
       "      <td>10484.139456</td>\n",
       "      <td>33643.08</td>\n",
       "      <td>38523.55</td>\n",
       "      <td>44534.30</td>\n",
       "      <td>55393.430</td>\n",
       "      <td>60632.75</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "      count          mean           std       min       25%       50%  \\\n",
       "M值层级                                                                    \n",
       "0     805.0    645.886970    502.084453      6.20    254.11    475.28   \n",
       "1     141.0   3575.166312   1290.594158   2114.33   2533.42   3213.59   \n",
       "2      27.0  11434.159259   3399.310286   7616.53   8242.11  10484.99   \n",
       "3       7.0  46663.441429  10484.139456  33643.08  38523.55  44534.30   \n",
       "\n",
       "            75%       max  \n",
       "M值层级                       \n",
       "0       954.090   2102.54  \n",
       "1      4405.880   7354.62  \n",
       "2     12870.455  19766.59  \n",
       "3     55393.430  60632.75  "
      ]
     },
     "execution_count": 209,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user['M值层级'] = kmeans_M.predict(df_user[['M值']])\n",
    "df_user = order_cluster('M值层级', 'M值', df_user, True)\n",
    "df_user.groupby('M值层级')['M值'].describe()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 210,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "      <th>F值</th>\n",
       "      <th>M值</th>\n",
       "      <th>R值层级</th>\n",
       "      <th>F值层级</th>\n",
       "      <th>M值层级</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "      <td>7</td>\n",
       "      <td>498.95</td>\n",
       "      <td>2</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "      <td>2</td>\n",
       "      <td>52.00</td>\n",
       "      <td>1</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "      <td>390</td>\n",
       "      <td>1201.51</td>\n",
       "      <td>2</td>\n",
       "      <td>2</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "      <td>15</td>\n",
       "      <td>628.38</td>\n",
       "      <td>1</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "      <td>324</td>\n",
       "      <td>5579.10</td>\n",
       "      <td>2</td>\n",
       "      <td>2</td>\n",
       "      <td>1</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值   F值       M值  R值层级  F值层级  M值层级\n",
       "0  14681   70    7   498.95     2     0     0\n",
       "1  14682  187    2    52.00     1     0     0\n",
       "2  14684   25  390  1201.51     2     2     0\n",
       "3  14687  106   15   628.38     1     0     0\n",
       "4  14688    7  324  5579.10     2     2     1"
      ]
     },
     "execution_count": 210,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_user = df_user.sort_values(by='用户码',ascending=True).reset_index(drop=True)\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "为用户整体分组画像"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 211,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>用户码</th>\n",
       "      <th>R值</th>\n",
       "      <th>F值</th>\n",
       "      <th>M值</th>\n",
       "      <th>R值层级</th>\n",
       "      <th>F值层级</th>\n",
       "      <th>M值层级</th>\n",
       "      <th>总分</th>\n",
       "      <th>总体价值</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>14681</td>\n",
       "      <td>70</td>\n",
       "      <td>7</td>\n",
       "      <td>498.95</td>\n",
       "      <td>2</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "      <td>2</td>\n",
       "      <td>低价值</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>14682</td>\n",
       "      <td>187</td>\n",
       "      <td>2</td>\n",
       "      <td>52.00</td>\n",
       "      <td>1</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>低价值</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>14684</td>\n",
       "      <td>25</td>\n",
       "      <td>390</td>\n",
       "      <td>1201.51</td>\n",
       "      <td>2</td>\n",
       "      <td>2</td>\n",
       "      <td>0</td>\n",
       "      <td>4</td>\n",
       "      <td>中价值</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>14687</td>\n",
       "      <td>106</td>\n",
       "      <td>15</td>\n",
       "      <td>628.38</td>\n",
       "      <td>1</td>\n",
       "      <td>0</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>低价值</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>14688</td>\n",
       "      <td>7</td>\n",
       "      <td>324</td>\n",
       "      <td>5579.10</td>\n",
       "      <td>2</td>\n",
       "      <td>2</td>\n",
       "      <td>1</td>\n",
       "      <td>5</td>\n",
       "      <td>高价值</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     用户码   R值   F值       M值  R值层级  F值层级  M值层级  总分 总体价值\n",
       "0  14681   70    7   498.95     2     0     0   2  低价值\n",
       "1  14682  187    2    52.00     1     0     0   1  低价值\n",
       "2  14684   25  390  1201.51     2     2     0   4  中价值\n",
       "3  14687  106   15   628.38     1     0     0   1  低价值\n",
       "4  14688    7  324  5579.10     2     2     1   5  高价值"
      ]
     },
     "execution_count": 211,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# 计算得分\n",
    "df_user['总分'] = df_user['R值层级'] + df_user['F值层级'] +  df_user['M值层级']\n",
    "\n",
    "# 计算总体价值\n",
    "df_user.loc[(df_user['总分']<=2) & (df_user['总分']>=0), '总体价值'] = '低价值'\n",
    "df_user.loc[(df_user['总分']<=4) & (df_user['总分']>=3), '总体价值'] = '中价值'\n",
    "df_user.loc[(df_user['总分']<=8) & (df_user['总分']>=5), '总体价值'] = '高价值'\n",
    "\n",
    "df_user.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "进一步分析"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 215,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<matplotlib.collections.PathCollection at 0x13419128>"
      ]
     },
     "execution_count": 215,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAYcAAAD8CAYAAACcjGjIAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADl0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uIDIuMi4zLCBodHRwOi8vbWF0cGxvdGxpYi5vcmcvIxREBQAAIABJREFUeJzt3Xt8VPWd//HXJzcCCbdwSTHhJtBu0VaqQVi0VKQi2Ba0tbuCFh6uXXZt8Wf7sFhs1wcC1VbbqvVGa6stdvGCYi1dqcpaXLtVkbDeuIhEtCaAEA1XuWUyn98fcyZOMhMyuU6SeT99zGPOfM/3XL4ZOZ8539sxd0dERCRWRqpPQEREOh4FBxERiaPgICIicRQcREQkjoKDiIjEUXAQEZE4Cg4iIhJHwUFEROIoOIiISJysVJ9Ac/Xv39+HDRuW6tMQEek0NmzY8IG7D0gmb6cNDsOGDaO0tDTVpyEi0mmY2d+TzatqJRERiaPgICIicRQcREQkjoKDiIjEUXAQEZE4Cg4iIp3E/qP7OeXuU9h/dH+bH0vBQUSkk3hy25Ns/mAzq7etbvNjJRUczKyPmT1mZm+a2RYz+0czKzCzNWa2LXjvG+Q1M7vDzMrM7HUzOz1mP3OC/NvMbE5M+hlm9kawzR1mZq1fVBGRzmnWylnk35TPnCcil83ZT8wm/6Z8Zq2c1WbHTPbO4RfAU+7+D8BpwBZgAfCsu48Cng0+A0wDRgWvucBSADMrABYC44AzgYXRgBLkmRuz3dSWFUtEpOtYPGkxQ3oPITsjG4DsjGyG9hnKkklL2uyYjQYHM+sFTATuA3D34+6+D5gBLAuyLQMuDJZnAA94xEtAHzMbBJwPrHH3KnffC6wBpgbrern7i+7uwAMx+xIRSXsjC0ayeNJiqsPV5GXnUR2uZtE5ixhRMKLNjpnMncPJQCXwWzN7x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},
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "# 显示高、中、低价值组分布散点图（F值与M值）\n",
    "plt.scatter(df_user.query(\"总体价值 == '高价值'\")['F值'],df_user.query(\"总体价值 == '高价值'\")['M值'],c='g', marker='*')\n",
    "plt.scatter(df_user.query(\"总体价值 == '中价值'\")['F值'],df_user.query(\"总体价值 == '中价值'\")['M值'], marker=8)\n",
    "plt.scatter(df_user.query(\"总体价值 == '低价值'\")['F值'],df_user.query(\"总体价值 == '低价值'\")['M值'],c='r' )\n",
    "\n",
    "\n",
    "# 高价值用户覆盖在消费频率较高的区域，与F值的相关度高\n",
    "# 消费金额大于 5000 元的用户中，中、高价值用户都有"
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3.7.0 ('base')",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.0"
  },
  "orig_nbformat": 4,
  "vscode": {
   "interpreter": {
    "hash": "ad2bdc8ecc057115af97d19610ffacc2b4e99fae6737bb82f5d7fb13d2f2c186"
   }
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
